{% load i18n %}
{% load zinnia %}

{% for comment in comments %}
<tr>
  <th>
    <img src="{% get_gravatar comment.email 40 "G" %}"
         class="gravatar photo" alt="{{ comment.name }}" />
  </th>
  <td>
    {% with entry=comment.content_object %}
    {% blocktrans with comment_author=comment.name comment_pk=comment.pk comment_author_slug=comment.user_name|slugify entry_url=entry.get_absolute_url entry_title=entry.title trimmed %}
    <strong>{{ comment_author }}</strong> in
    <strong>
      <a href="{{ entry_url }}#comment-{{ comment_pk }}-by-{{ comment_author_slug }}"
         title="Comment on {{ entry_title }}">
        {{ entry_title }}
      </a>
    </strong>
    {% endblocktrans %}
    {% endwith %}
    {{ comment.comment|truncatewords:20|linebreaks }}
  </td>
  <td>
    <a href="{% url 'change'|comment_admin_urlname comment.pk %}"
       title="{% trans "Edit the comment" %}" class="changelink">
      {% trans "Edit" %}
    </a>
  </td>
</tr>
{% empty %}
<tr>
  <th colspan="3">
    {% trans "No comments yet." %}
  </th>
</tr>
{% endfor %}

{% if comments %}
<tr>
  <th colspan="3">
    <a href="{% url 'changelist'|comment_admin_urlname %}"
       title="{% trans "Manage the comments" %}" class="managelink">
      {% trans "Manage the comments" %}
    </a>
  </th>
</tr>
{% endif %}
